﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using OOAD_Project_Engine.Foundation.Interfaces;
using OOAD_Project_Engine.Application.Services;

namespace OOAD_Project_Editor.Domain.ManageSceneActions
{
    [Action(ActionType = EActionType.RemoveEntityComponent)]
    class RemoveEntityComponentAction : ManageSceneAction
    {
        IEntity entity;
        IEntityComponent component;
        public RemoveEntityComponentAction(ISceneService scene, IEntity entity, IEntityComponent component)
            : base(scene)
        {
            this.entity = entity;

            this.component = component;
        }

        public override void DoAction()
        {
            entity.Remove(component);
        }
    }
}
